import httpRequest from "@/http"
import { type MyResponseType } from "@/bean/base/response";
import { type MyPageResponseType } from "@/bean/base/page";
import { MkMember } from "@/bean/mk/MkMember";


export const memberAllApi = () => {
    return httpRequest.postNoParam<MyResponseType<Array<MkMember>>>("/mk/member/all");
}

export const memberListApi = (params:Object) => {
    return httpRequest.post<MyResponseType<MyPageResponseType<MkMember>>>("/mk/member/list",params);
}


export const addMemberApi = (params:Object) => {
    return httpRequest.post<MyResponseType<object>>("/mk/member/add",params);
}


export const updateMemberApi = (params:Object) => {
    return httpRequest.post<MyResponseType<object>>("/mk/member/update",params);
}

export const delMemberApi = (params:Number) => {
    return httpRequest.postLink<MyResponseType<object>>(`/mk/member/delete`,params);
}